/***********************************************************************
 * Module:  NhanVien.cs
 * Author:  Tuan Nguyen
 * Purpose: Definition of the Class NhanVien
 ***********************************************************************/

using System;

public class NhanVien
{
   public long MaNhanVien;
   public string TenNhanVien;
   public DateTime NgaySinhNv;
   public string DiaChiNv;
   public string DiDongNv;
   public string EmailNv;
   public string SoCmnd;
   public bool GioiTinhNv;
   public long MucLuong;
   
   public System.Collections.ArrayList Lam_Viec_Tai;
   
   /// <pdGenerated>default getter</pdGenerated>
   public System.Collections.ArrayList GetLam_Viec_Tai()
   {
      if (Lam_Viec_Tai == null)
         Lam_Viec_Tai = new System.Collections.ArrayList();
      return Lam_Viec_Tai;
   }
   
   /// <pdGenerated>default setter</pdGenerated>
   public void SetLam_Viec_Tai(System.Collections.ArrayList newLam_Viec_Tai)
   {
      RemoveAllLam_Viec_Tai();
      foreach (PhongBan oPhongBan in newLam_Viec_Tai)
         AddLam_Viec_Tai(oPhongBan);
   }
   
   /// <pdGenerated>default Add</pdGenerated>
   public void AddLam_Viec_Tai(PhongBan newPhongBan)
   {
      if (newPhongBan == null)
         return;
      if (this.Lam_Viec_Tai == null)
         this.Lam_Viec_Tai = new System.Collections.ArrayList();
      if (!this.Lam_Viec_Tai.Contains(newPhongBan))
      {
         this.Lam_Viec_Tai.Add(newPhongBan);
         newPhongBan.AddLam_Viec_Tai(this);      
      }
   }
   
   /// <pdGenerated>default Remove</pdGenerated>
   public void RemoveLam_Viec_Tai(PhongBan oldPhongBan)
   {
      if (oldPhongBan == null)
         return;
      if (this.Lam_Viec_Tai != null)
         if (this.Lam_Viec_Tai.Contains(oldPhongBan))
         {
            this.Lam_Viec_Tai.Remove(oldPhongBan);
            oldPhongBan.RemoveLam_Viec_Tai(this);
         }
   }
   
   /// <pdGenerated>default removeAll</pdGenerated>
   public void RemoveAllLam_Viec_Tai()
   {
      if (Lam_Viec_Tai != null)
      {
         System.Collections.ArrayList tmpLam_Viec_Tai = new System.Collections.ArrayList();
         foreach (PhongBan oldPhongBan in Lam_Viec_Tai)
            tmpLam_Viec_Tai.Add(oldPhongBan);
         Lam_Viec_Tai.Clear();
         foreach (PhongBan oldPhongBan in tmpLam_Viec_Tai)
            oldPhongBan.RemoveLam_Viec_Tai(this);
         tmpLam_Viec_Tai.Clear();
      }
   }
   public System.Collections.ArrayList chiTietHoaDon;
   
   /// <pdGenerated>default getter</pdGenerated>
   public System.Collections.ArrayList GetChiTietHoaDon()
   {
      if (chiTietHoaDon == null)
         chiTietHoaDon = new System.Collections.ArrayList();
      return chiTietHoaDon;
   }
   
   /// <pdGenerated>default setter</pdGenerated>
   public void SetChiTietHoaDon(System.Collections.ArrayList newChiTietHoaDon)
   {
      RemoveAllChiTietHoaDon();
      foreach (ChiTietHoaDon oChiTietHoaDon in newChiTietHoaDon)
         AddChiTietHoaDon(oChiTietHoaDon);
   }
   
   /// <pdGenerated>default Add</pdGenerated>
   public void AddChiTietHoaDon(ChiTietHoaDon newChiTietHoaDon)
   {
      if (newChiTietHoaDon == null)
         return;
      if (this.chiTietHoaDon == null)
         this.chiTietHoaDon = new System.Collections.ArrayList();
      if (!this.chiTietHoaDon.Contains(newChiTietHoaDon))
      {
         this.chiTietHoaDon.Add(newChiTietHoaDon);
         newChiTietHoaDon.SetNhanVien(this);      
      }
   }
   
   /// <pdGenerated>default Remove</pdGenerated>
   public void RemoveChiTietHoaDon(ChiTietHoaDon oldChiTietHoaDon)
   {
      if (oldChiTietHoaDon == null)
         return;
      if (this.chiTietHoaDon != null)
         if (this.chiTietHoaDon.Contains(oldChiTietHoaDon))
         {
            this.chiTietHoaDon.Remove(oldChiTietHoaDon);
            oldChiTietHoaDon.SetNhanVien((NhanVien)null);
         }
   }
   
   /// <pdGenerated>default removeAll</pdGenerated>
   public void RemoveAllChiTietHoaDon()
   {
      if (chiTietHoaDon != null)
      {
         System.Collections.ArrayList tmpChiTietHoaDon = new System.Collections.ArrayList();
         foreach (ChiTietHoaDon oldChiTietHoaDon in chiTietHoaDon)
            tmpChiTietHoaDon.Add(oldChiTietHoaDon);
         chiTietHoaDon.Clear();
         foreach (ChiTietHoaDon oldChiTietHoaDon in tmpChiTietHoaDon)
            oldChiTietHoaDon.SetNhanVien((NhanVien)null);
         tmpChiTietHoaDon.Clear();
      }
   }
   public System.Collections.ArrayList chiTietDonDatHang;
   
   /// <pdGenerated>default getter</pdGenerated>
   public System.Collections.ArrayList GetChiTietDonDatHang()
   {
      if (chiTietDonDatHang == null)
         chiTietDonDatHang = new System.Collections.ArrayList();
      return chiTietDonDatHang;
   }
   
   /// <pdGenerated>default setter</pdGenerated>
   public void SetChiTietDonDatHang(System.Collections.ArrayList newChiTietDonDatHang)
   {
      RemoveAllChiTietDonDatHang();
      foreach (ChiTietDonDatHang oChiTietDonDatHang in newChiTietDonDatHang)
         AddChiTietDonDatHang(oChiTietDonDatHang);
   }
   
   /// <pdGenerated>default Add</pdGenerated>
   public void AddChiTietDonDatHang(ChiTietDonDatHang newChiTietDonDatHang)
   {
      if (newChiTietDonDatHang == null)
         return;
      if (this.chiTietDonDatHang == null)
         this.chiTietDonDatHang = new System.Collections.ArrayList();
      if (!this.chiTietDonDatHang.Contains(newChiTietDonDatHang))
      {
         this.chiTietDonDatHang.Add(newChiTietDonDatHang);
         newChiTietDonDatHang.SetNhanVien(this);      
      }
   }
   
   /// <pdGenerated>default Remove</pdGenerated>
   public void RemoveChiTietDonDatHang(ChiTietDonDatHang oldChiTietDonDatHang)
   {
      if (oldChiTietDonDatHang == null)
         return;
      if (this.chiTietDonDatHang != null)
         if (this.chiTietDonDatHang.Contains(oldChiTietDonDatHang))
         {
            this.chiTietDonDatHang.Remove(oldChiTietDonDatHang);
            oldChiTietDonDatHang.SetNhanVien((NhanVien)null);
         }
   }
   
   /// <pdGenerated>default removeAll</pdGenerated>
   public void RemoveAllChiTietDonDatHang()
   {
      if (chiTietDonDatHang != null)
      {
         System.Collections.ArrayList tmpChiTietDonDatHang = new System.Collections.ArrayList();
         foreach (ChiTietDonDatHang oldChiTietDonDatHang in chiTietDonDatHang)
            tmpChiTietDonDatHang.Add(oldChiTietDonDatHang);
         chiTietDonDatHang.Clear();
         foreach (ChiTietDonDatHang oldChiTietDonDatHang in tmpChiTietDonDatHang)
            oldChiTietDonDatHang.SetNhanVien((NhanVien)null);
         tmpChiTietDonDatHang.Clear();
      }
   }
   public System.Collections.ArrayList chiTietPhieuXuatKho;
   
   /// <pdGenerated>default getter</pdGenerated>
   public System.Collections.ArrayList GetChiTietPhieuXuatKho()
   {
      if (chiTietPhieuXuatKho == null)
         chiTietPhieuXuatKho = new System.Collections.ArrayList();
      return chiTietPhieuXuatKho;
   }
   
   /// <pdGenerated>default setter</pdGenerated>
   public void SetChiTietPhieuXuatKho(System.Collections.ArrayList newChiTietPhieuXuatKho)
   {
      RemoveAllChiTietPhieuXuatKho();
      foreach (ChiTietPhieuXuatKho oChiTietPhieuXuatKho in newChiTietPhieuXuatKho)
         AddChiTietPhieuXuatKho(oChiTietPhieuXuatKho);
   }
   
   /// <pdGenerated>default Add</pdGenerated>
   public void AddChiTietPhieuXuatKho(ChiTietPhieuXuatKho newChiTietPhieuXuatKho)
   {
      if (newChiTietPhieuXuatKho == null)
         return;
      if (this.chiTietPhieuXuatKho == null)
         this.chiTietPhieuXuatKho = new System.Collections.ArrayList();
      if (!this.chiTietPhieuXuatKho.Contains(newChiTietPhieuXuatKho))
      {
         this.chiTietPhieuXuatKho.Add(newChiTietPhieuXuatKho);
         newChiTietPhieuXuatKho.SetNhanVien(this);      
      }
   }
   
   /// <pdGenerated>default Remove</pdGenerated>
   public void RemoveChiTietPhieuXuatKho(ChiTietPhieuXuatKho oldChiTietPhieuXuatKho)
   {
      if (oldChiTietPhieuXuatKho == null)
         return;
      if (this.chiTietPhieuXuatKho != null)
         if (this.chiTietPhieuXuatKho.Contains(oldChiTietPhieuXuatKho))
         {
            this.chiTietPhieuXuatKho.Remove(oldChiTietPhieuXuatKho);
            oldChiTietPhieuXuatKho.SetNhanVien((NhanVien)null);
         }
   }
   
   /// <pdGenerated>default removeAll</pdGenerated>
   public void RemoveAllChiTietPhieuXuatKho()
   {
      if (chiTietPhieuXuatKho != null)
      {
         System.Collections.ArrayList tmpChiTietPhieuXuatKho = new System.Collections.ArrayList();
         foreach (ChiTietPhieuXuatKho oldChiTietPhieuXuatKho in chiTietPhieuXuatKho)
            tmpChiTietPhieuXuatKho.Add(oldChiTietPhieuXuatKho);
         chiTietPhieuXuatKho.Clear();
         foreach (ChiTietPhieuXuatKho oldChiTietPhieuXuatKho in tmpChiTietPhieuXuatKho)
            oldChiTietPhieuXuatKho.SetNhanVien((NhanVien)null);
         tmpChiTietPhieuXuatKho.Clear();
      }
   }
   public System.Collections.ArrayList ChiLatVatTaiQuay;

}